﻿using Domain.Base;
using DtoFw.Enum;
using SqlSugar;

namespace Domain.Entity
{
    ///<summary>
    ///后台用户
    ///</summary>
    [SugarTable("system_user")]
    [DB(EnumDatabase.Mysql, Cache = false)]
    public class MainUserEntity: BaseEntity
    {
        [SugarColumn(ColumnName = "Name")]
        public System.String Name { get; set; }
        [SugarColumn(ColumnName = "NickName")]
        public string NickName { get; set; }
        [SugarColumn(ColumnName = "Sex")]
        public System.Int32? Sex { get; set; }
        [SugarColumn(ColumnName = "PoliceNo")]
        public System.String PoliceNo { get; set; }
        [SugarColumn(ColumnName = "UserNo")]
        public System.String UserNo { get; set; }

        [SugarColumn(ColumnName = "Pwd")]
        public System.String Pwd { get; set; }

        [SugarColumn(ColumnName = "OrgId")]
        public System.Int64 OrgId { get; set; } = 0;

        [SugarColumn(ColumnName = "OrgDeptId")]
        public System.Int64 OrgDeptId { get; set; } = 0;

        [SugarColumn(ColumnName = "Phone")]
        public System.String Phone { get; set; }

        [SugarColumn(ColumnName = "Email")]
        public System.String Email { get; set; }

        [SugarColumn(ColumnName = "Ip")]
        public System.String Ip { get; set; }

        [SugarColumn(ColumnName = "CardType")]
        public int CardType { get; set; } = 1;

        [SugarColumn(ColumnName = "CardNo")]
        public System.String CardNo { get; set; }
        [SugarColumn(ColumnName = "Birthday")]
        public System.DateTime? Birthday { get; set; }

        [SugarColumn(ColumnName = "Rank")]
        public System.String Rank { get; set; }

        [SugarColumn(ColumnName = "RankName")]
        public System.String RankName { get; set; }

        [SugarColumn(ColumnName = "Post")]
        public System.String Post { get; set; }

        [SugarColumn(ColumnName = "PostName")]
        public System.String PostName { get; set; }

        [SugarColumn(ColumnName = "Fax")]
        public System.String Fax { get; set; }

        [SugarColumn(ColumnName = "LastLoginTime")]
        public System.DateTime? LastLoginTime { get; set; }

        [SugarColumn(ColumnName = "EmpStatus")]
        public int EmpStatus { get; set; }

        [SugarColumn(ColumnName = "UserStatus")]
        public int UserStatus { get; set; }

        [SugarColumn(ColumnName = "UserType")]
        public System.String UserType { get; set; }

        [SugarColumn(ColumnName = "OrderBy")]
        public System.Int32? OrderBy { get; set; }

        [SugarColumn(ColumnName = "Remark")]
        public System.String Remark { get; set; }

        [SugarColumn(ColumnName = "Extend1")]
        public System.String Extend1 { get; set; }

        [SugarColumn(ColumnName = "Extend2")]
        public System.String Extend2 { get; set; }

        [SugarColumn(ColumnName = "Extend3")]
        public System.String Extend3 { get; set; }

        [SugarColumn(ColumnName = "Extend4")]
        public System.String Extend4 { get; set; }

        [SugarColumn(ColumnName = "Extend5")]
        public System.String Extend5 { get; set; }

        [SugarColumn(ColumnName = "Salt")]
        public System.String Salt { get; set; }

        [SugarColumn(ColumnName = "IsDisable")]
        public int IsDisable {
            get {
                return UserStatus;
            }
            set {
                value = UserStatus;
            } }

    }
}
